package org.tomcat.object;

import java.util.LinkedList;
import java.util.Queue;

public class WaitNotifyMain {

    private volatile static Queue<Integer> queue = new LinkedList<>();

    public static void main(String[] args) {
        Producer producer = new Producer(queue, 10);
        producer.setName("Producer");
        Consumer consumer = new Consumer(queue, 10);
        consumer.setName("Consumer");

        producer.start();
        consumer.start();
    }
}
